#ifndef SIP_SXSERVICEMGR_HPP__
#define SIP_SXSERVICEMGR_HPP__

#include "WTSXSipService/SipWTSXServiceItf.hpp"
#include "WTSXSipService/SipWTSXTypes.hpp"

#include <set>

namespace wtsxsip{


class WTSX_SIPSRV_PUBLIC CSipSXServiceMgr
{
public:

    virtual ~CSipSXServiceMgr(void);

    static CSipSXServiceMgr* instance();

    bool finit();

    ISipSXService* generateService();

    bool insertService(ISipSXService* service);

    bool destroyService(ISipSXService* service);

private:

    //bool encodeKey(std::string& key, const SNetAddr& addr);    

    CSipSXServiceMgr(void);

private:

    static CSipSXServiceMgr* s_instance;

    std::set<ISipSXService*> m_servicePool;
};



}//namespace

#endif


